#pragma once

namespace dotNetInteropPlugin {
	namespace PluginDev {
		using namespace System;
		using namespace System::Collections;
		using namespace System::Collections::Generic;


		/// <summary>
		/// Represent root menu item as combination of menu item and it's category
		/// </summary>
		public value class RootMenuItem
		{
		public:
			/// <summary>
			/// Creates new root menu item
			/// </summary>
			/// <param name="MN">Category</param>
			/// <param name="MI">MenuItem</param>
			RootMenuItem(AIMPPlayerMenu MN, MAIMPMenuItem^ MI)
			{
				inPlayerMenu = MN;
				inMenuItem = MI;
			}


			/// <summary>
			/// Menu item category
			/// </summary>
			property AIMPPlayerMenu PlayerMenu 
			{ 
				AIMPPlayerMenu get()
				{
					return inPlayerMenu;
				}
			}

			/// <summary>
			/// Menu item
			/// </summary>
			property MAIMPMenuItem^ MenuItem
			{
				MAIMPMenuItem^ get()
				{
					return inMenuItem;
				}
			}
		private:
			AIMPPlayerMenu inPlayerMenu;
			MAIMPMenuItem^ inMenuItem;
		};

		//========================

		/// <summary>
		/// Menu manager
		/// </summary>
		public interface class IMAIMPMenuManager: public System::Collections::Generic::ICollection<RootMenuItem>
		{
		public:
			/// <summary>
			/// Gets root MenuItem by index
			/// </summary>
			property RootMenuItem default[Int32]
			{
				RootMenuItem get(Int32 index) abstract;
			}

			/// <summary>
			/// Remove menu item by index
			/// </summary>
			/// <param name="index">index</param>
			void RemoveAt(Int32 index) abstract;
			
			/// <summary>
			/// Add new root menu item
			/// </summary>
			/// <param name="MN">Category</param>
			/// <param name="MI">Menu item</param>
			void Add(AIMPPlayerMenu MN, MAIMPMenuItem^ MI) abstract;
		};

	}
}